import { GTable } from 'geminis-react';

export default () => {
  const schema = {
    headerTitle: '货品批次信息',
    data: {
      url: '/api/warehouse/basic/productBatch',
      include: ['product', 'vendor'],
      sort: 'product.no:asc,no:asc',
    },
    action: {
      toolbar: {
        add: {
          form: {
            schemaPath: '/warehouse-pc/schema/basic/productBatch/edit.json',
          },
        },
        delete: true,
        excelExport: true,
        excelImport: true,
      },
      row: {
        edit: true,
        delete: true,
      },
    },
  };

  return (
    <GTable
      schemaPath="/warehouse-pc/schema/basic/productBatch/table.json"
      schema={schema}
    />
  );
};
